ImageGear .NET v25.2 - Updated
WriteDirectText(ImGearOCRPage[],String) Method




ImageGear.OCR Assembly > ImageGear.OCR Namespace > ImGearOCR Class > WriteDirectText Method : WriteDirectText(ImGearOCRPage[],String) Method
Array of ImGearOCRPage objects with the valid recognition data to be saved.
A relative or absolute path for the file where the recognition data will be saved.
Writes the recognition data of several pages to the file in the one of text formats.
Syntax
'Declaration
 
Public Overloads MustOverride Sub WriteDirectText( _
   ByVal pages() As ImGearOCRPage, _
   ByVal filePath As String _
) 
'Usage
 
Dim instance As ImGearOCR
Dim pages() As ImGearOCRPage
Dim filePath As String
 
instance.WriteDirectText(pages, filePath)
public abstract void WriteDirectText( 
   ImGearOCRPage[] pages,
   string filePath
)
public: abstract void WriteDirectText( 
   ImGearOCRPage*[]* pages,
   string* filePath
) 
public:
abstract void WriteDirectText( 
   array<ImGearOCRPage^>^ pages,
   String^ filePath
) 

Parameters

pages
Array of ImGearOCRPage objects with the valid recognition data to be saved.
filePath
A relative or absolute path for the file where the recognition data will be saved.
Exceptions
ExceptionDescription
Argument pages, one or more values of pages array or argument filePath is null.
Argument filePath is empty string or this string refers incorrect file system resource.
Directory for file is not found.
Argument filePath is not correct.
Argument filePath contains too long path for file system.
Given page or parent of given page is disposed.
Remarks

Use ImGearOCRSettings.DirectTextFormat to get or set the current direct text output format.

For ImGearOCRDirectTextFormat.SimpleText, ImGearOCRDirectTextFormat.CommaSeparatedText and ImGearOCRDirectTextFormat.FormattedText text formats if file parameter specifies an existing file name, the text outputs are appended to the end of file. In case of ImGearOCRDirectTextFormat.XmlWithCoordinates text format if file parameter refers existing file the content of this file will be replaced with new text output.

See Also

Reference

ImGearOCR Class
ImGearOCR Members
Overload List
WriteDirectText(ImGearOCRPage,Stream) Method
WriteDirectText(ImGearOCRPage,String) Method
WriteDirectText(ImGearOCRPage[],String) Method

Is this page helpful?
Yes No
Thanks for your feedback.